/*
 all - js | Copyright : http://urang-kurai.blogspot.com
*/
$(function (U, K) {
        var aY = $(document),
            bC = $(window),
            aO = $("html"),
            bT = $("html, body"),
            aV = $("body"),
            bX = $("#sec"),
            bQ = $("#min"),
            bO = $("#hours"),
            aK = $("#box"),
            ad = $("#backtotop"),
            bj = $("#activator"),
            bW = $("#boxclose"),
            bZ = $("#arsiptor"),
            be = $("#playTour a"),
            Qa = $(".shared_this"),
            Qb = $(".grid-c1"),
            Qc = $(".gambar"),
            Qd = $('.lightbox'),
            a6 = $("#overlay,#notice-right"),
            aa = $("#notice,#overlay"),
            ax = $("#daf-menu-close"),
            aL = $("#daf-menu"),
            bM = $("#submitButton"),
            bs = $("#like-fb-close"),
            aH = $("#nav-left  a"),
            aN = $("#nav-right  a"),
            aF = $("#loading"),
            a3 = $("#tweet"),
            a0 = $("#nav-up"),
            aM = $("#nav-down"),
            bi = $("#slideout-holder"),
            aZ = $("#slideout-expand"),
            aE = $("#slideout"),
            aP = $("#slideout-holder,.article .nav"),
            aW = $("#slideout-collapse"),
            aA = $("#slideout-holder,.nav"),
            af = $("#slideout-expand,.activator"),
            az = $("#box,#overlay,.comment-icon"),
            bg = $("#notice"),
            bF = $("#notice-right"),
            aS = $("#notice-content"),
            bu = $("#notice-right-index"),
            bH = $("#notice,#notice-right-index"),
            bo = $("#overlay,#like-fb"),
            a4 = $("#overlay"),
            bD = $("#like-fb"),
            aT = $("#overlay,.open-bottom-nav"),
            bA = $("#bottom-nav"),
            bx = $("#box,.comment-icon,.close-bottom-nav"),
            ac = $("#searchInContainer .active"),
            bc = $("#notice-content,#notice-right-index"),
            ab = $("#resultsDiv,#more,#more1"),
            bb = $("#resultsDiv,#more,#more1,.clear-img"),
            bS = $("#closes-tip,.end-all-menu .next-tipp"),
            au = $("#overlay-all-menu,.center-start-menu"),
            ai = $("#holder-x31 h1,#Terms-and-Conditions-content,#PrivacyPolicy-content,#logo-kurai .urangkurai"),
            bU = $("#overlay-all-menu-1,#overlay-all-menu,.end-all-menu,.left-right-menu,.right-notice-menu,.top-permalink-menu,.bottom-komment-menu,.bottom-search-menu"),
            aX = $("a.Blog1naf-left"),
            aR = $("a.Blog1nav-right"),
            bI = $(".search-template img"),
            ae = $(".footergrd-c3"),
            ak = $(".profil-dep-home p a"),
            bY = $(".Date"),
            br = $(".fb-likes-x,#like-fb-close"),
            bn = $(".fb-likes-x"),
            bG = $(".close-bottom-nav"),
            bk = $(".fotter-fixed"),
            bf = $(".open-bottom-nav"),
            ay = $(".comment-icon"),
            ba = $(".center-start-menu ,#overlay-all-menu"),
            bw = $(".left-right-menu,#overlay-all-menu-1"),
            bv = $(".center-start-menu a.next-tipp"),
            bl = $(".center-start-menu"),
            bz = $(".left-right-menu"),
            a8 = $(".left-right-menu a.next-tipp"),
            a7 = $(".right-notice-menu a.next-tipp"),
            b1 = $(".right-notice-menu"),
            bh = $(".top-permalink-menu"),
            a9 = $(".top-permalink-menu a.next-tipp"),
            bV = $(".bottom-komment-menu"),
            aw = $(".bottom-komment-menu a.next-tipp"),
            bN = $(".bottom-search-menu"),
            aC = $(".bottom-search-menu a.next-tipp"),
            aI = $(".end-all-menu"),
            bE = $(".left-right-menu .bxxx-content,.right-notice-menu .bxxx-content,.top-permalink-menu .bxxx-content,.bottom-komment-menu .bxxx-content,.bottom-search-menu .bxxx-content"),
            a5 = $("section#logo-home div.text,section#logo-home div.logo,section#logo-home div.arrow,section#logo-home div.freedom"),
            am = $("section#logo-home div.text"),
            ah = $("section#logo-home div.logo"),
            ao = $("section#logo-home div.arrow"),
            bL = $("section#logo-home div.freedom"),
            a2 = $(".article #nav-left"),
            aB = $(".article #nav-left"),
            bB = $(".article #nav-right"),
            bq = $(".article #notice-top-menu"),
            aj = $("article.blog-search,li#blog-pager-newer-link,li#blog-pager-older-link,.search-template"),
            bP = $("aside#bawahbana"),
            a1 = $("aside#bawahbana p a"),
            bJ = $(".clear-img"),
            by = $("li#like-fb-close"),
            xa = $('.profil-dep-home p.labels-tag'),
            xb = $('.tag_labels'),
            SH = '<ul class="share-wrapper"><h2>Share this : ' + dataposttitle + '</h2><li><a class="fb_share" href="http://www.facebook.com/sharer.php?u=' + dataposturl + '" target="_blank">Facebook</a></li><li><a class="twitter_share" href="http://twitter.com/share?url=' + dataposturl + '" target="_blank">Twitter</a></li><li><a class="google_share" href="https://plus.google.com/share?url=' + dataposturl + '" target="_blank">Google+</a></li><li><iframe class="fb-item" allowTransparency="true" frameborder="0" scrolling="no" src="http://www.facebook.com/plugins/like.php?href=' + dataposturl + '&send=false&layout=button_count&show_faces=false&width=79&action=like&colorscheme=light"></iframe></li></ul>';
            xb.html(xa.children().clone());
        function al(d, b, f) {
            if (f) {
                var c = new Date;
                c.setTime(c.getTime() + f * 24 * 60 * 60 * 1000);
                var a = "; expires=" + c.toGMTString()
            } else {
                var a = ""
            }
            document.cookie = d + "=" + b + a + "; path=/"
        }

        function bm(d) {
            var b = d + "=";
            var f = document.cookie.split(";");
            for (var c = 0; c < f.length; c++) {
                var a = f[c];
                while (a.charAt(0) == " ") {
                    a = a.substring(1, a.length)
                }
                if (a.indexOf(b) == 0) {
                    return a.substring(b.length, a.length)
                }
            }
            return null
        }

        function bR(a) {
            al(a, "", -1)
        }

        function av(b, a, c) {
            $(b).each(function () {
                $(this).attr({
                    src: $(this).attr("src").replace("/s" + a + "/", "/s" + c + "-c/"),
                    width: c,
                    height: c
                })
            })
        }

        function ar() {
            function k(c) {
                c = $.extend({}, q, c);
                c.term = c.term || $("#s").val();
                if (c.searchSite) {
                    c.term = "site:" + c.V9 + " " + c.term
                }
                var a = "http://ajax.googleapis.com/ajax/services/search/" + c.type + "?v=1.0&callback=?";
                var f = $("#resultsDiv");
                $.getJSON(a, {
                    q: c.term,
                    rsz: c.perPage,
                    start: c.page * c.perPage
                }, function (h) {
                    var n = h.responseData.results;
                    $("#more").remove();
                    if (n.length) {
                        var e = $("<div>", {
                            className: "pageContainer"
                        });
                        for (var l = 0; l < n.length; l++) {
                            e.append(new x(n[l]) + "")
                        }
                        if (!c.append) {
                            f.empty()
                        }
                        e.append('<div class="clear"></div>').hide().appendTo(f).fadeIn("slow");
                        var p = h.responseData.cursor;
                        if (+p.estimatedResultCount > (c.page + 1) * c.perPage) {
                            $("<div>", {
                                id: "more"
                            }).appendTo(f).click(function () {
                                k({
                                    append: true,
                                    page: c.page + 1
                                });
                                $(this).fadeOut()
                            })
                        }
                    } else {
                        f.empty();
                        $("<h3>", {
                            className: "notFound",
                            html: "No Results Were Found!"
                        }).hide().appendTo(f).fadeIn()
                    }
                })
            }

            function x(c) {
                var a = [];
                switch (c.GsearchResultClass) {
                case "GwebSearch":
                    a = ['<div class="webResult">', '<div class="sinp">', '<a  class="linkwebsite" href="', c.unescapedUrl, '" target="_blank">', c.visibleUrl, "</a>", "</div>", '<div class="titlee">', '<h2><a href="', c.unescapedUrl, '" target="_blank">', c.title, "</a></h2>", "</div>", "</div>", '<div class="clear"></div>'];
                    break;
                case "GimageSearch":
                    a = ['<div class="imageResult">', '<a target="_blank" href="', c.unescapedUrl, '" title="', c.titleNoFormatting, '" class="pic" style="width:', c.tbWidth, "px;height:", c.tbHeight, 'px;">', '<img class="img-items" src="', c.unescapedUrl, '" width="185px" ', '" height="210px" ', c.tbWidth, '" height="', c.tbHeight, '" /></a>', '<div class="clear"></div>', '<a class="webtitle" href="', c.originalContextUrl, '" target="_blank">', "</a>", "</div>"];
                    break;
                case "GvideoSearch":
                    a = ['<div class="imageResult">', '<a target="_blank" href="', c.unescapedUrl, '" title="', c.titleNoFormatting, '" class="pic" style="width:', c.tbWidth, "px;height:", c.tbHeight, 'px;">', '<img class="img-items" src="', c.unescapedUrl, '" width="185px" ', '" height="210px" ', c.tbWidth, '" height="', c.tbHeight, '" /></a>', '<div class="clear"></div>', '<a class="webtitle" href="', c.originalContextUrl, '" target="_blank">', "</a>", "</div>"];
                    break;
                case "GnewsSearch":
                    a = ['<div class="webResult">', '<div class="sinp">', '<a  class="linkwebsite" href="', c.unescapedUrl, '" target="_blank">', c.publisher, "</a>", "</div>", '<div class="titlee">', '<h2><a href="', c.unescapedUrl, '" target="_blank">', c.title, "</a></h2>", "</div>", "</div>", '<div class="clear"></div>'];
                    break
                }
                this.toString = function () {
                    return a.join("")
                }
            }
            var w = $("#searchSite,#searchWeb"),
                A = $("#submitButton"),
                j = $("article.blog-search,li#blog-pager-newer-link,li#blog-pager-older-link,.search-template"),
                b = $("#siteNameLabel"),
                m = $("#searchSite"),
                B = $("li.web"),
                g = $("#s"),
                z = $("#searchForm"),
                y = $("#more1"),
                v = $("#more");
            var q = {
                V9: "urang-kurai.blogspot.com",
                searchSite: true,
                type: "web",
                append: false,
                perPage: 8,
                page: 1
            };
            var d = $("<span>", {
                className: "arrow"
            }).appendTo("ul.icons");
            $("ul.icons li").click(function () {
                var a = $(this);
                if (a.hasClass("active")) {
                    return false
                }
                a.siblings().removeClass("active");
                a.addClass("active");
                d.stop().animate({
                    left: a.position().left,
                    marginLeft: a.width() / 2 - 4
                });
                q.type = a.attr("data-searchType");
                v.fadeOut()
            });
            b.append(" " + q.V9);
            m.click();
            B.click();
            g.focus();
            z.submit(function () {
                k();
                return false
            });
            w.change(function () {
                q.searchSite = this.id == "searchSite"
            });
            A.click(function () {
                j.hide(500)
            });
            A.click(function () {
                y.show(500)
            })
        }
        ar();
        var bK = function () {
            var a = this;
            this.b = "//urang-kurai-blogspot.googlecode.com/svn/trunk/UK/image/";
            this.s = ["A.png", "B.png", "C.png", "D.png"];
            this.i = this.s[this.random(this.s.length)];
            this.f = this.b + this.i;
            this.n = document.createElement("img");
            this.newSpeed().newPoint().display().newPoint().fly()
        };
        bK.prototype.display = function () {
            $(this.n).attr("src", this.f).css("position", "absolute").css("z-index", this.random(20)).css("top", this.pointY).css("left", this.pointX);
            ai.append(this.n);
            return this
        };
        bK.prototype.fly = function () {
            var a = this;
            $(this.n).animate({
                top: this.pointY,
                left: this.pointX
            }, this.speed, "linear", function () {
                a.newSpeed().newPoint().fly()
            })
        };
        bK.prototype.newSpeed = function () {
            this.speed = (this.random(10) + 5) * 1100;
            return this
        };
        bK.prototype.newPoint = function () {
            this.pointX = this.random(window.innerWidth - 810);
            this.pointY = this.random(450);
            return this
        };
        bK.prototype.random = function (a) {
            return Math.ceil(Math.random() * a) - 1
        };
        var ap = 125;
        var b0 = [];
        for (aU = 0; aU < ap; aU++) {
            b0[aU] = new bK()
        }
        aY.keydown(function (b) {
            var a = false;
            if (b.which == 37) {
                a = aH.attr("href")
            } else {
                if (b.which == 39) {
                    a = aN.attr("href")
                }
            } if (a) {
                window.location = a
            }
        });
        var ag = window.applicationCache;
        var V9 = "http://" + top.location.host.toString();
        var VX = $(".nav a[href^='" + V9 + "'],.nav  a[href^='/'],.nav  a[href^='./'],.nav  a[href^='../'],.nav  a[href^='#'],.footerwrap a[href^='" + V9 + "'],.footerwrap  a[href^='/'],.footerwrap a[href^='./'],.footerwrap a[href^='../'],.footerwrap a[href^='#']");
        if (window.applicationCache.status == 0 || window.applicationCache.status == 3) {
            var aQ = {
                lines: 120,
                length: 70,
                width: 2,
                radius: 90,
                color: "#444",
                speed: 0.9,
                trail: 90,
                shadow: false
            };
            $.fn.spin = function (a) {
                this.each(function () {
                    var b = $(this),
                        c = b.data();
                    if (c.spinner) {
                        c.spinner.stop();
                        delete c.spinner
                    }
                    if (a !== false) {
                        c.spinner = (new Spinner($.extend({
                            color: b.css("color")
                        }, a))).spin(this)
                    }
                });
                return this
            };
            aF.spin(aQ);
            setTimeout(function () {
                aF.fadeOut(1500)
            }, 1000)
        } else {
            aF.hide()
        }
        VX.click(function () {
            aF.fadeIn().delay(10000).fadeOut(10000);
        });
        aF.click(function () {
            $(this).hide();
        });
        var bd = "andre_pandet";
        $.getJSON("http://api.twitter.com/1/statuses/user_timeline/" + bd + ".json?count=1&callback=?", function (a) {
            $.each(a, function (c, b) {
                a3.html(b.text)
            })
        });
        var aD = aX.attr("href");
        aX.load(aD + " .post-title:first", function () {
            var a = aX.text();
            aX.text("" + a)
        });
        var an = aR.attr("href");
        aR.load(an + " .post-title:first", function () {
            var a = aR.text();
            aR.text(a + " ")
        });
        aO.css("display", "none");
        a0.click(function () {
            aV.stop().scrollTo({
                top: "-=350px",
                left: "+=0"
            }, 500)
        });
        aM.click(function () {
            aV.stop().scrollTo({
                top: "+=350px",
                left: "+=0"
            }, 500)
        });
        aZ.click(function () {
            aE.animate({
                left: "0px"
            }, "slow");
            $(this).fadeOut(0);
            aP.css({
                "z-index": "1032"
            });
            aW.fadeIn(0);
            a2.css("background-image", "url(http://1.bp.blogspot.com/-NYP8ZSs2Tio/T0-4HypStuI/AAAAAAAAHec/Ldh4vVVKx3U/s1600/home.png)");
            aB.css("background-image", "url(http://1.bp.blogspot.com/-IOVsHWxPJ7g/T0-4ACYJlaI/AAAAAAAAHeU/mMAxJJOTp1E/s1600/nav-light.png)");
            bB.css("background-image", "url(http://1.bp.blogspot.com/-IOVsHWxPJ7g/T0-4ACYJlaI/AAAAAAAAHeU/mMAxJJOTp1E/s1600/nav-light.png)")
        });
        aW.click(function () {
            aE.animate({
                left: "-=360px"
            }, "slow");
            $(this).fadeOut(0);
            aZ.fadeIn(0);
            bi.css({
                "z-index": "100"
            });
            a2.css("background-image", "");
            aB.css("background-image", "");
            bB.css("background-image", "")
        });
         Qa.html(SH);
         Qb.hover(function () {
            Qc.addClass("active");
        }, function () {
            Qc.removeClass("active");
        });

        jQuery("abbr.timeago").timeago();
        Qd.lightbox();
        aA.delay(3500).animate({
            left: "26px"
        }, 500);
        bg.delay(3500).animate({
            right: "26px"
        }, 500);
        bq.delay(3500).animate({
            right: "33px"
        }, 500);
        bF.click(function () {
            aS.show("20"), $(this).fadeOut(0), bu.fadeIn("fast");
            bH.css({
                "z-index": "1020"
            });
            bo.fadeIn(), br.fadeOut()
        });
        bu.click(function () {
            aS.hide("20"), $(this).fadeOut(0), bF.fadeIn("fast");
            bH.css({
                "z-index": "100"
            });
            a4.fadeOut("fast")
        });
        bD.click(function () {
            bn.slideToggle("20"), $(this).fadeOut(0), by.fadeIn("fast");
            bg.css({
                "z-index": "1040"
            });
            a6.fadeIn(), bc.fadeOut(0), aa.fadeIn("fast")
        });
        bs.click(function () {
            bn.slideToggle("20"), $(this).fadeOut(), bD.fadeIn("fast");
            bg.css({
                "z-index": "100"
            });
            a4.fadeOut("fast")
        });
        bk.delay(3500).animate({
            bottom: "0"
        }, 500);
        ad.click(function (a) {
            a.preventDefault();
            bT.animate({
                scrollTop: 0
            }, "slow")
        });
        bj.click(function () {
            a4.fadeIn("fast", function () {
                aK.animate({
                    top: "8%"
                }, 350)
            })
        });
        bW.click(function () {
            aK.animate({
                top: "-620px"
            }, 200, function () {
                a4.fadeOut("fast")
            })
        });
        bZ.click(function () {
            aK.animate({
                top: "-620px"
            }, 100, function () {})
        });
        bZ.click(function () {
            a4.fadeIn("fast", function () {
                aL.animate({
                    top: "8%"
                }, 350)
            })
        });
        ax.click(function () {
            aL.animate({
                top: "-620px"
            }, 200, function () {
                a4.fadeOut("fast")
            })
        });
        bj.click(function () {
            aL.animate({
                top: "-620px"
            }, 100, function () {})
        });
        aZ.click(function () {
            aT.fadeIn();
            bx.fadeOut("200")
        });
        aW.click(function () {
            az.fadeIn();
            aK.animate({
                top: "8%"
            }, 350)
        });
        bM.click(function () {
            bJ.show(0)
        });
        bJ.click(function () {
            aj.show(0);
            bb.hide(0)
        });
        ac.click(function () {
            ab.show("300");
            aj.hide("300")
        });
        bf.click(function () {
            bA.slideToggle("300");
            aK.animate({
                top: "-620px"
            }, 200, function () {
                a4.fadeIn("fast");
                bk.css({
                    "z-index": "1020"
                })
            });
            var a = $(".bottom-nav-grid ");
            a.animate({
                width: "600px",
                opacity: "0.4"
            }, "slow");
            a.animate({
                width: "800px",
                opacity: "0.8"
            }, "slow")
        });
        bG.click(function () {
            bA.slideToggle("300");
            $(this).fadeOut();
            bf.fadeIn();
            a4.fadeOut("fast");
            bk.css({
                "z-index": "100"
            })
        });
        bG.fadeOut();
        af.click(function () {
            bA.fadeOut("100");
            $closebottomnav.fadeOut();
            bf.fadeIn()
        });
        bf.click(function () {
            aE.animate({
                left: "-=360px"
            }, "slow");
            $(this).fadeOut();
            bG.fadeIn(), ay.fadeIn("40"), bc.fadeOut("40"), bF.fadeIn("40")
        });
        ba.delay(3500).fadeIn("slow");
        be.click(function () {
            bw.fadeIn("slow")
        });
        bv.click(function () {
            bl.fadeOut(), bz.fadeIn("slow");
            al("menuReturnNotice-bx", null, 9999999999);
            return false
        });
        a8.click(function () {
            bz.fadeOut(), b1.fadeIn("slow")
        });
        a7.click(function () {
            b1.fadeOut(), bh.fadeIn("slow")
        });
        a9.click(function () {
            bh.fadeOut(), bV.fadeIn("slow")
        });
        aw.click(function () {
            bV.fadeOut(), bN.fadeIn("slow")
        });
        aC.click(function () {
            bN.fadeOut(), aI.fadeIn("slow")
        });
        bE.append('<a href="#" id="closes-tip">X</a>');
        $(".end-all-menu .next-tipp,#closes-tip").click(function () {
            bU.fadeOut(), bq.fadeIn("200");
            al("noticetopmenuShow", null, 9999999999);
            return false
        });
        if (bm("menuReturnNotice-bx")) {
            au.remove()
        }
        if (bm("noticetopmenuShow")) {
            bq.css("display", "block")
        }
        a5.hide();
        am.delay(600).fadeIn(600);
        ah.delay(800).fadeIn(800);
        ao.delay(1200).fadeIn(1200);
        bL.delay(1400).fadeIn(1400);
        av(".search-templates .gambar img", "1600", "200");
        bI.delay(1200).fadeIn(1200);
        bP.hover(function () {
            a1.css("text-decoration", "underline", 1000)
        }, function () {
            a1.css("text-decoration", "none"), 1000
        });
        ae.hover(function () {
            ak.css("text-decoration", "underline", 1000)
        }, function () {
            ak.css("text-decoration", "none"), 1000
        });
        var ag = ["January", "February", "March", "April", "May", "June", "July", "August", "September", "October", "November", "December"];
        var aQ = ["Sunday", "Monday", "Tuesday", "Wednesday", "Thursday", "Friday", "Saturday"];
        var bd = new Date;
        bd.setDate(bd.getDate());
        bY.html(aQ[bd.getDay()] + " " + bd.getDate() + " " + ag[bd.getMonth()] + " " + bd.getFullYear());
        setInterval(function () {
            var a = (new Date).getSeconds();
            bX.html((a < 10 ? "0" : "") + a)
        }, 1000);
        setInterval(function () {
            var a = (new Date).getMinutes();
            bQ.html((a < 10 ? "0" : "") + a)
        }, 1000);
        setInterval(function () {
            var a = (new Date).getHours();
            bO.html((a < 10 ? "0" : "") + a)
        }, 1000);
        bC.mousemove(function (a) {
            $(".home-link").text("X = " + a.pageX + ", Y = " + a.pageY)
        });

        window.onload = function () {
            var a = document.getElementById("ss-form");
            a.onsubmit = function () {
                var b = window.open("about:blank", "Popup_Window", "toolbar=0,scrollbars=0,location=0,statusbar=0,menubar=0,resizable=0,width=350,height=220,left = 300,top = 400");
                this.target = "Popup_Window"
            };
            var a = document.getElementById("ss-form1");
            a.onsubmit = function () {
                var b = window.open("about:blank", "Popup_Window", "toolbar=0,scrollbars=0,location=0,statusbar=0,menubar=0,resizable=0,width=350,height=220,left = 300,top = 400");
                this.target = "Popup_Window"
            }
        };
        Cufon.replace("span.judul1,ul.dot-icon li,h3.notFound,.U-kurai-Capture-it", {
            fontFamily: "U-kurai-Capture-it"
        });
        Cufon.replace("span.judul,.judul-atas-slide,.nav-message,.errorpage-text1,.knockout48", {
            fontFamily: "knockout48"
        });
        Cufon.replace(".knockout49", {
            fontFamily: "knockout49"
        });
        Cufon.replace(".data-title,.threecol h5,div#phone h2.phone-number,.container h5,h5.title-grd,article#grid-archive #bp_toc table .judul-posting a:link,li.judul-posting,.Kurai-UK-bold", {
            fontFamily: "Kurai UK bold"
        });
        Cufon.replace("nav#topnav li a:link,.gambar-p > .text-p p,.Kurai-UK-Normal", {
        fontFamily: "Kurai UK Normal"
        });
        })(jQuery);